package com.ae.shield.api;

import net.minecraft.entity.LivingEntity;
import net.minecraft.item.ItemStack;
import net.minecraft.util.DamageSource;
import net.minecraftforge.energy.IEnergyStorage;

public interface IShield {
    /**
     *
     * @param livingEntity 持有护盾的实体
     * @param stack 被触发的护盾发生器
     * @param amount 伤害量
     * @param source 伤害来源
     * @param energyCap 护盾容器的能量能力
     * @return 该护盾无法处理的伤害
     */
    float onEntityHurt(LivingEntity livingEntity, ItemStack stack, float amount, DamageSource source, IEnergyStorage energyCap);
    boolean onEntityDeath(ItemStack stack, LivingEntity livingEntity, DamageSource source, IEnergyStorage energyCap);
}
